package itcast.service.impl;

import itcast.dao.ScoredromDao;
import itcast.dao.impl.ScoredromDaoImpl;
import itcast.domain.Score;
import itcast.service.ScoredromService;

import java.util.List;

public class ScoredromServiceImpl implements ScoredromService {
    ScoredromDao scoredromDao=new ScoredromDaoImpl();
    //查找评分宿舍信息

    @Override
    public List<Score> findscoredromAll() {
        return scoredromDao.findscore_dromAll();
    }
    //添加宿舍评分信息

    @Override
    public void addscore_drom(Score score) {
        scoredromDao.insertscore(score);
    }
    //根据id删除数据

    @Override
    public void deleteScore_drom(String id) {
        scoredromDao.delete_scoredrom(Integer.parseInt(id));
    }
}
